﻿using System;
using System.Collections.Generic;
using System.Data.SQLite;

namespace JinianNet.JNCms.SQLiteDAL
{
    public class SQLiteHelper : JinianNet.Data.DbHelper
    {
        public SQLiteHelper()
            : base(JinianNet.JNCms.Fileds.ConnectionString)
        {
        }

        public SQLiteHelper(string connectionString)
            : base(connectionString)
        {

        }

        protected override System.Data.Common.DbConnection CreateConnection()
        {
            return new SQLiteConnection();
        }

        protected override System.Data.Common.DbCommand CreateCommand()
        {
            return new SQLiteCommand();
        }

        protected override System.Data.Common.DbDataAdapter CreateDataAdapter()
        {
            return new SQLiteDataAdapter();
        }

        protected override System.Data.Common.DbParameter CreateParameter()
        {
            return new SQLiteParameter();
        }

        public override string GetPageSql(System.Data.Common.DbConnection connection, System.Data.Common.DbCommand cmd, string SqlAllFields, string SqlTablesAndWhere, string IndexField, string OrderFields, int PageIndex, int PageSize)
        {
            throw new NotImplementedException();
        }
    }
}
